# Contributor: Milan P. Stanić <mps@arvanta.net>
# Maintainer: Milan P. Stanić <mps@arvanta.net>
pkgname=ell
pkgver=0.51
pkgrel=0
pkgdesc="Linux library for embedded development"
url="https://01.org/ell"
arch="all"
license="GPL-2.0-only"
makedepends="glib-dev linux-headers"
checkdepends="dbus"
subpackages="$pkgname-dev"
source="https://mirrors.edge.kernel.org/pub/linux/libs/ell/ell-$pkgver.tar.gz
	0001-build-fix-time.h-related-breakage-on-musl.patch
	"

case "$CARCH" in
aarch64|arm*) options="!check" ;;
esac

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--enable-glib
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
7b7897ea094ad90eeae98594f701b846f4f8c25cddab7ad2b38676d3b6369f26013e3f9f40086ae5e602325aa14daadc4d7923dea4609271d5ed11586eb9969d  ell-0.51.tar.gz
9543fb27bf364848798e9219de57e8fa60b46372ff0719769d413957098ed4ee6835a4a2661536214a8bcd48b94f8a30217770eb243be01669f8d47fbec11c3d  0001-build-fix-time.h-related-breakage-on-musl.patch
"
